package com.easonji.common.base.response.enums;

/**
 * @ClassName: ResponseEnum
 * @Description: 统一响应枚举
 * @Author: LiuJun
 * @date: 2018/07/22 11:25
 * @Version: 1.0
 * @Copyright: Copyright (c) 2018 - 2019
 */
public enum ResponseEnum {
    /**
     * 成功响应统一枚举
     */
    LOGIN_SUCCESS(200, "登陆成功"), QUERY_SUCCESS(200, "查询成功"), SAVE_SUCCESS(200, "添加成功"), UPDATE_SUCCESS(200,
            "修改成功"), REMOVE_SUCCESS(200, "删除成功"), ADD_ROLE_AUTHORITY_SUCCESS(200, "权限配置成功"), RESET_PWD_SUCCESS(200,
                    "密码重置成功"), FREEZE_USER_SUCCESS(200, "冻结用户成功"), UNFREEZE_USER_SUCCESS(200,
                            "解除冻结用户成功"), USER_ROLEASSIGN_SUCCESS(200, "用户角色分配成功"), USER_APPASSIGN_SUCCESS(200,
                                    "用户应用分配成功"), USER_CHPWD_SUCCESS(200, "密码修改成功"),
    /**
     * 签名成功
     */
    AUTH_SUCCESS(200, "签名成功"),
    /**
     * 审核
     */
    AUDI_SUCCESS(200,"审核成功"),AUDI_01_ERROR(400,"该申请已经审核"),
    /**
     * 错误的请求
     */
    PARAMETER_ERROR(400, "请求内容有错误"), DATABASE_ERROR(400, "数据库错误"), SYSTEM_ERROR(500, "服务器异常"), NOT_FOUND(404,
            "信息不存在"), TIMEOUT(408, "会话超时");

    ResponseEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    private Integer code;

    private String message;

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
